Conversation
| * PUT /path -> 2xx (successful update/create with body B) | ||
| * GET /path -> 2xx (must return exactly the fields that were PUT) | ||
| * | ||
| * Returns true if any field sent in the PUT body has a different value |
There was a problem hiding this comment.
this is partial. you need also to check that GET is not returning fields not used in the PUT. or, if those are returned, if they are null
There was a problem hiding this comment.
also, need to check the differences in what declared in the schema, eg, the resource might have fields that are not supposed to be changed via a PUT (eg timestamps or ids)
| val putBody = extractRequestBody(put) | ||
| val getBody = resGet.getBody() | ||
|
|
||
| if (putBody.isNullOrEmpty() || getBody.isNullOrEmpty()) return false |
There was a problem hiding this comment.
if putBody is empty, but getBody is not, then we got a bug
|
|
||
| if (putBody.isNullOrEmpty() || getBody.isNullOrEmpty()) return false | ||
|
|
||
| val fieldNames = extractModifiedFieldNames(put) |
There was a problem hiding this comment.
here it should rather check the field names of what declared in the schema of the PUT. i have added some more discussion and examples to 2026/httporacles/notes.txt
| * Sequence checked: | ||
| * PUT /X body=B -> 2xx | ||
| * GET /X -> response body must match exactly B | ||
| * (no field from a previous state should bleed through) |
There was a problem hiding this comment.
see updated discussion at 2026/httporacles/notes.txt
| @Test | ||
| fun testRunEM() { | ||
|
|
||
| runTestHandlingFlakyAndCompilation( |
There was a problem hiding this comment.
not sure if best in a E2E or an integration test, but check to verify the example discussed in 2026/httporacles/notes.txt, especially making sure that K does not lead to flag a fault (ie false positive)
No description provided.